<!--
    (c) 2007, Stephane Alnet

    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 3
    of the License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-->

<input type="hidden" name="_method" value="apply_sip" id="_method">

<TMPL_LOOP name="sip_peers">
    <fieldset>
        <legend>SIP Peer <TMPL_VAR NAME="peer_name"></legend>
        <p>
            <label for="<TMPL_VAR NAME="peer_name">_mode">Mode</label>
            <select name="<TMPL_VAR NAME="peer_name">_mode" id="<TMPL_VAR NAME="peer_name">_mode" trigger="yes">
                <option value="unused" is_default="true">Unused</option>
                <option value="sipt">SIP Trunking</option>
            </select>
        </p>
        <div <TMPL_VAR NAME="peer_name">_mode="sipt">
        <p>
            <label for="<TMPL_VAR NAME="peer_name">_hostname">IP Address or DNS name</label>
            <input type="text" name="<TMPL_VAR NAME="peer_name">_hostname" id="<TMPL_VAR NAME="peer_name">_hostname" value="" />
        </p>
        <p>
            <label for="<TMPL_VAR NAME="peer_name">_username">Username</label>
            <input type="text" name="<TMPL_VAR NAME="peer_name">_username" id="<TMPL_VAR NAME="peer_name">_username" value="" />
        </p>
        <p>
            <label for="<TMPL_VAR NAME="peer_name">_password">Password</label>
            <input type="text" name="<TMPL_VAR NAME="peer_name">_password" id="<TMPL_VAR NAME="peer_name">_password" value="" />
        </p>
        </div>
    </fieldset>
</TMPL_LOOP>
